home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 10034 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  61 lines

  1. Path: newsbf02.news.aol.com!not-for-mail
  2. From: mrbig0233@aol.com (MrBig0233)
  3. Newsgroups: comp.lang.c++
  4. Subject: HELP! Compile Error!
  5. Date: 5 Mar 1996 15:25:16 -0500
  6. Organization: America Online, Inc. (1-800-827-6364)
  7. Sender: root@newsbf02.news.aol.com
  8. Message-ID: <4hi7vc$ggd@newsbf02.news.aol.com>
  9. Reply-To: mrbig0233@aol.com (MrBig0233)
  10. NNTP-Posting-Host: newsbf02.mail.aol.com
  11.  
  12. I am an 11-year-old (yes, no typo) programmer, and I am trying to write a
  13. sorting program for a merit badge. I compile the program, and the error
  14. is:
  15.  
  16. SORT.CPP 7: Declaration terminated incorrectly
  17.  
  18. This is the code:
  19.  
  20. #include<conio.h>
  21. #include<stdio.h>
  22. #include<stdlib.h>
  23. #include<time.h>
  24. #include<string.h>
  25.  
  26. {
  27.  
  28.     main()
  29.     randomize(num1);
  30.     randomize(num2);
  31.     randomize(num3);
  32.     randomize(num4);
  33.     randomize(num5);
  34.     if (strcmp(num1==<num2))
  35.     {
  36.         strcpy(num2,num1);
  37.     }
  38.     if (strcmp(num2==<num3))
  39.     {
  40.         strcpy(num3,num2);
  41.     }
  42.     if (strcmp(num3==<num4))
  43.     {
  44.         strcpy(num4,num3);
  45.     }
  46.     if (strcmp(num4==<num5))
  47.     {
  48.         strcpy(num5,num4);
  49.     }
  50.     printf("The numbers, in some order:\n");
  51.     printf("%d, %d, %d, %d, %d",num1,num2,num3,num4,num5);
  52.     return;
  53. }
  54.     
  55. Please reply to this message! I NEED AN ANSWER!
  56. Please, in your answer, also tell me how to fix it.
  57.  
  58. E-Mail:
  59.  
  60. MrBig0233@aol.com
  61.